package org.jeecg.modules.demo.ch.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.modules.demo.ch.entity.WeeklyReportFeedback;
import org.jeecg.modules.demo.ch.mapper.WeeklyReportFeedbackMapper;
import org.jeecg.modules.demo.ch.service.IWeeklyReportFeedbackService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Description: 周报反馈系统
 * @Author: jeecg-boot
 * @Date:   2022-11-14
 * @Version: V1.0
 */
@Service
public class WeeklyReportFeedbackServiceImpl extends ServiceImpl<WeeklyReportFeedbackMapper, WeeklyReportFeedback> implements IWeeklyReportFeedbackService {
    @Autowired
    private WeeklyReportFeedbackMapper weeklyReportFeedbackMapper;

    @Override
    public List<WeeklyReportFeedback> selectChWeeklyReportFeedbackListByTime(Integer pageNo, Integer pageSize, String executor, String executionStatus,String classification,String weeklyMeetTitle,String representation, String beginTime, String endTime,String permissionSql) {
        pageNo = (pageNo-1)*pageSize;
        return weeklyReportFeedbackMapper.selectChWeeklyReportFeedbackListByTime(pageNo, pageSize, executor, executionStatus,classification, weeklyMeetTitle, representation, beginTime, endTime,permissionSql);
    }

    @Override
    public int selectChWeeklyReportFeedbackListTotalByTime(String executor, String executionStatus,String classification,String weeklyMeetTitle,String representation,  String beginTime, String endTime,String permissionSql) {
        return weeklyReportFeedbackMapper.selectChWeeklyReportFeedbackListTotalByTime(executor, executionStatus, classification, weeklyMeetTitle, representation, beginTime, endTime, permissionSql);
    }

    @Override
    public List<WeeklyReportFeedback> selectChWeeklyReportFeedbackListForLastWeek(String beginTime, String endTime) {
        return weeklyReportFeedbackMapper.selectChWeeklyReportFeedbackListForLastWeek(beginTime,endTime);
    }
}
